<?php
interface Pageley_Gateway {
	public function getTransaction($existing = true, $singleStatement = false);

	public function find($type, $id);
	
	public function findByProperty($type, $propertyName, $value);

	public function query($query);
    
    public function count($query);

	public function insert($entity);

	public function update($entity);

	public function delete($entity);
    
    public function transactionComplete($transaction);
    
    public function generateId($subject);
}